package net.dopan.pigframe.user.service.impl;

import net.dopan.pigframe.core.base.service.impl.BaseServiceImpl;
import net.dopan.pigframe.user.mapper.SysUserRoleMapper;
import net.dopan.pigframe.user.model.entity.SysUserRole;
import net.dopan.pigframe.user.service.SysUserRoleService;
import org.springframework.stereotype.Service;

/**
 * @Package: net.dopan.pigframe.user.service.impl
 * @Title: SysUserRoleServiceImpl
 * @Description: 用户角色表 服务实现类
 * @author: 刘宽
 * @date: 2018/9/2 21:10
 */
@Service
public class SysUserRoleServiceImpl extends BaseServiceImpl<SysUserRoleMapper, SysUserRole> implements SysUserRoleService {

    /**
     * 根据用户Id删除该用户的角色关系
     *
     * @param userId 用户ID
     * @return boolean
     */
    @Override
    public Boolean deleteByUserId(Integer userId) {
        return baseMapper.deleteByUserId(userId);
    }
}
